Skip to content

Add support for new MSAPP format with ControlPropertyState and Category properties - #762

Merged
Marcel Ferreira (marcelbf) merged 7 commits into
masterfrom
marcelbf/container
Oct 13, 2025
Merged

Marcel Ferreira (marcelbf) merged 7 commits into
masterfrom
marcelbf/container

Conversation

@marcelbf

Copy link
Copy Markdown
Contributor

#759 #756 #755 #754

Problem

The PASopa tool was failing to pack new MSAPP format files that contain ControlPropertyState properties in dynamic properties. These properties are used by PowerApps Studio for responsive layout metadata and rule categorization. The tool was encountering JSON deserialization errors because the schema didn't support these new properties.

Solution

Enhanced the schema definitions to support the new MSAPP format properties and fixed serialization issues to ensure proper roundtrip compatibility. The solution preserves both the logic and metadata (ControlPropertyState, Category) for dynamic properties while maintaining backward compatibility.

Changes

  • Add ControlPropertyState and Category fields to schema classes
  • Add logic to handle Category and ControlPropertyState in the IRStateHelper.

Validation

Add a new MSAPP file with these properties, to be executed with RoundtripTests.
All RoundtripTests pass (36/36)
All tests running
Successfully tested pack/unpack operations on new MSAPP format files with 0 errors
Verified backward compatibility with existing MSAPP files without the new properties
Confirmed that the solution handles both scenarios: properties with rules + metadata, and metadata-only properties

…ic properties.

Add app with categoty and ControlPropertyState to test (RoundripTests)

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for the new MSAPP format that includes ControlPropertyState and Category properties used by PowerApps Studio for responsive layout metadata and rule categorization. The changes ensure proper serialization/deserialization and maintain backward compatibility.

  • Added Category field to RuleEntry and PropertyState classes for rule categorization
  • Added ControlPropertyState field to DynamicPropertyJson and DynamicPropertyState classes for responsive layout metadata
  • Enhanced logic in IRStateHelpers to handle the new properties during pack/unpack operations

Reviewed Changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.

File Description
src/PAModel/Schemas/adhoc/Control.cs Added Category and ControlPropertyState schema fields
src/PAModel/IR/IRStateHelpers.cs Enhanced property handling logic and serialization for new fields
src/PAModel/EditorState/PropertyState.cs Added Category field to PropertyState class
src/PAModel/EditorState/DynamicPropertyState.cs Added ControlPropertyState field to DynamicPropertyState class

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread src/PAModel/IR/IRStateHelpers.cs
Comment thread src/PAModel/IR/IRStateHelpers.cs Outdated
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@microsoft Microsoft (microsoft) deleted a comment from Copilot AI Oct 12, 2025
@microsoft Microsoft (microsoft) deleted a comment from Copilot AI Oct 12, 2025
@marcelbf
Marcel Ferreira (marcelbf) merged commit e8eaa93 into master Oct 13, 2025
7 checks passed
@marcelbf
Marcel Ferreira (marcelbf) deleted the marcelbf/container branch October 13, 2025 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants